<template>
  <img style="width: 100%;height: 100%;" :src="imageUrl"/>
  <div class="back-btn" @click="goBack">
    返回主菜单
  </div>
</template>

<script setup>
import {computed} from "vue";
import router from "@/router";

const imageUrl = computed(() => {
  return require(`../assets/info/${router.currentRoute.value.query.name || "tongyong"}.png`)
})

const goBack = () => {
  router.push({name: "home"})
}
</script>

<style lang="scss" scoped>
img{
  display: block;
}
.back-btn {
  color: #fff;
  background-color: #538be2;
  width: 100%;
  height: 30px;
  margin-bottom: 10px;
}
</style>
